package com.example.shilehui;

import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;

import cn.jhc.Adapter.SelectYearRankingUserrMeritsBookAdapter;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.widget.Adapter;
import android.widget.ImageView;
import android.widget.ListView;

public class SearchYearRankingUserMeritsBookActivity extends Activity {
	
	private ListView listView;
	private ImageView back;
	private Adapter adapter;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		init();
		Calendar cal = Calendar.getInstance();
		int year = cal.get(Calendar.YEAR);
		
		ArrayList<String> data=new ArrayList<String>();
		for (int i = 2007; i <= year; i++) {
			data.add(String.valueOf(i));
		}
		SelectYearRankingUserrMeritsBookAdapter yearRankingUserrMeritsBookAdapter=new SelectYearRankingUserrMeritsBookAdapter(this,this,data);
		listView.setAdapter(yearRankingUserrMeritsBookAdapter);
	}
	
	public void init(){
		requestWindowFeature(Window.FEATURE_NO_TITLE);
		setContentView(R.layout.select_year_ranking_merits_book);
		listView=(ListView) findViewById(R.id.select_year_ranking_merits_book_listview);	
		back=(ImageView) findViewById(R.id.select_year_ranking_merits_book_title_left_imageview);
	}
	
	public void initAdapter(Adapter adapter){
		this.adapter=adapter;
	}
	
	public void initAdapterData(){
		 
	}
	
	public void select_year_back(View v){
		finish();
	}
	
}
